import * as THREE from 'three'
import createApp from '../../core'

function createBox3Helper (dom: HTMLElement) {
  const { camera, scene } = createApp(dom)
  camera.position.set(-80, 120, 100)
  camera.lookAt(scene.position)

  const axesHelper = new THREE.AxesHelper(50)
  scene.add(axesHelper)

  const box = new THREE.Box3()
  box.setFromCenterAndSize(new THREE.Vector3(0, 0, 0), new THREE.Vector3(20, 10, 33))

  const helper = new THREE.Box3Helper(box, new THREE.Color(0xffff00))
  scene.add(helper)
}

export {
  createBox3Helper
}
